// logs.ts
// const util = require('../../utils/util.js')
Page({
  data: {
    collectCells: [{}],
  },
  onReady() {
    const app = getApp();
    if (!app.globalData.isLogin) {
      wx.redirectTo({
        url: '/pages/login/login',
        success: () => {
          console.log('重定向到登录页成功');
        },
        fail: (err) => {
          console.log('重定向到登录页失败', err);
        }
      });
    }
    this.setData({
      collectCells: [
        {
          title: '日常投料以及损耗上报',
          route: '/pages/feedCollect/feedCollect'
        },
        {
          title: '分塘记录上报',
          route: '/pages/transferCollect/transferCollect'
        },
        {
          title: '销售记录上报',
          route: '/pages/saleCollect/saleCollect'
        },
        {
          title: '清塘损耗上报',
          route: '/pages/cleanCollect/cleanCollect'
        },
        {
          title: '新苗投塘上报',
          route: '/pages/putCollect/putCollect'
        },
      ]
    });
    console.log(app.globalData.userInfo);

  },
});
